<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
    <script>
        //如果比较左右运算符两边任意一边有数字 会将字符串转为数字在比较
        console.log(3>10);
        console.log(3>'10');
        console.log('3'>10);
        //如果比较运算符左右两边都是字符串,比较字符串的编码值
        console.log('3'>'10');
        console.log('宇'>'博');
        console.log('程小宇'.charCodeAt(2));
        console.log('博'.charCodeAt());

        console.log(Number('3'),typeof Number('3'));//3
        console.log(Number(true),typeof Number(true));//1
        console.log(Number(false),typeof Number(false));//0
        console.log(Number('你好'),typeof Number('你好'));//NOT a Number


        let a=1;
        let b=true;
        console.log(a==b);//true
        console.log(a===b);//false
    </script>
</body>
</html>